﻿using System;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System.Collections.Generic;
using System.IO;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;

namespace Wedn.Net.UnitTest
{
    [TestClass]
    public class UnitTest1
    {
        [TestMethod]
        public void TestMethod1()
        {
            //string url = "a.com";
            //Dictionary<string, string> data = new Dictionary<string, string>() { { "a", "ad" }, { "aa", "ad" } };
            //url = url + "?" + string.Join("&", data);
            ////string str = StringHelper.Encrypt("5love100");
            ////Console.Write(str);
            //Console.WriteLine(url);

            //string jsonText = @"{""input"" : ""value"", ""output"" : ""result""}";
            //JsonReader reader = new JsonTextReader(new StringReader(jsonText));

            //while (reader.Read())
            //{
            //    Console.WriteLine(reader.TokenType + "\t\t" + reader.ValueType + "\t\t" + reader.Value);
            //}

            string jsonText = "{\"beijing\":{\"zone\":\"海淀\",\"zone_en\":\"haidian\"}}";
            JObject jo = (JObject)JsonConvert.DeserializeObject(jsonText);
            string zone = jo["beijing"]["zone"].ToString();
            string zone_en = jo["beijing"]["zone_en"].ToString();

            List<string> list=new List<string>();
            list.ToArray();

            string[] arr=new string[0];
        }

    }
}
